//
//  JBWBindingPhoneViewController.m
//  JBWDSK
//
//  Created by 崔志伟 on 2018/7/30.
//  Copyright © 2018年 崔志伟. All rights reserved.
//

#import "JBWBindingPhoneViewController.h"
#import "JBWVerificationCodeBtn.h"
@interface JBWBindingPhoneViewController ()
@property (nonatomic,strong) JBWPlaceholderUITextField  * phoneTextField ;
@property (nonatomic,strong) JBWPlaceholderUITextField  * passwordTextField ;
@property (nonatomic,strong) UIButton *showPasswordBtn  ;
@property (nonatomic,strong) JBWVerificationCodeBtn  * verificationCodeBtn ;
@property (nonatomic,strong) UITextField  * verificationCodeTextField ;
@property (nonatomic,strong) UIButton  * sureBtn ;
@end

@implementation JBWBindingPhoneViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.mainNavView.backTitle = @"绑定手机";
    [self setUpInputPasswordView];

}



- (void)setUpInputPasswordView {
    // 手机号码
    self.phoneTextField = [[JBWPlaceholderUITextField alloc]initWithFrame:CGRectMake(15, 0, CGRectGetWidth(self.contenView.frame)-130, 44)];
    self.phoneTextField.placeholder = @"手机号码";
    self.phoneTextField.secureTextEntry = YES;
    self.phoneTextField.font =  [UIFont systemFontOfSize:13];
    [self.contenView  addSubview:self.phoneTextField];
    self.verificationCodeBtn = [[JBWVerificationCodeBtn alloc]initWithFrame:CGRectMake(CGRectGetMaxX(self.phoneTextField.frame), 8, 90, 44-16)];
    __block JBWVerificationCodeBtn *blockBtn = self.verificationCodeBtn;
    self.verificationCodeBtn.clickblock = ^{
        [blockBtn startAnimating];
    };
    [self.contenView  addSubview:self.verificationCodeBtn ];
    
    UIView *centerLine = [[UIView alloc]initWithFrame:CGRectMake(15, 44, CGRectGetWidth(self.contenView .frame)-30, 1)];
    centerLine.backgroundColor = [UIColor grayColor];
    [self.contenView  addSubview:centerLine];
    
    
    
    //验证码
    self.verificationCodeTextField = [[JBWPlaceholderUITextField alloc]initWithFrame:CGRectMake(15, 45, CGRectGetWidth(self.contenView .frame)-30, 44)];
    self.verificationCodeTextField.font =  [UIFont systemFontOfSize:13];
    self.verificationCodeTextField.placeholder = @"验证码";
    [self.contenView  addSubview:self.verificationCodeTextField];
    
    
    UIView *bottomLine = [[UIView alloc]initWithFrame:CGRectMake(15, 90, CGRectGetWidth(self.contenView .frame)-30, 1)];
    bottomLine.backgroundColor = [UIColor grayColor];
    [self.contenView  addSubview:bottomLine];
    
    UIButton *authenticationBtn = [[UIButton alloc]initWithFrame:CGRectMake(15, 120, self.contenView.frame.size.width-30, 40)];
    authenticationBtn.backgroundColor = [UIColor orangeColor];
    [authenticationBtn setTitle:@"认证" forState:UIControlStateNormal];
    [authenticationBtn setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
    authenticationBtn.titleLabel.font = [UIFont systemFontOfSize:15];
    authenticationBtn.layer.cornerRadius = 5;
    authenticationBtn.layer.masksToBounds = YES;
    [authenticationBtn addTarget:self action:@selector(authenticationBtnAction) forControlEvents:UIControlEventTouchUpInside];
    [self.contenView addSubview:authenticationBtn];
    
    
    
}
-(void)authenticationBtnAction{
    
    
}
@end
